import { Permission } from "@/service/general/modal/common";

interface KnowledgeBaseModal {
    agentModel?: string,
    avatar?: string,
    createTime?: string,
    id: string,
    intro?: string,
    name?: string,
    type?: string,
    updateTime?: string,
    userId?: string,
    vectorModel?: string,
    inheritPermission?: boolean,
    parentId?: string,
    status?: string,
    teamId?: string,
    tmbId?: string,
    __v?: number,
    _id?: string,
}

interface DataSetModal {
    _id?: string,
    tmbId? :string,
    parentId?: string,
    name?: string,
    type?: string,
    dataAmount?: number,
    trainingAmount?: number,
    trainingType?: string,
    forbid?: boolean,
    permission?: Permission,
    createTime?: Date,
    updateTime?: Date,
}

interface DateSetDetailModal {
    chunkSize?: number,
    createTime?: Date,
    dataset?: KnowledgeBaseModal,
    datasetId?: string,
    forbid?: boolean,
    indexAmount?: number,
    hashRawText?: string,
    name?: string,
    parentId?: string,
    permission?: Permission,
    rawTextLength?: number,
    sourceName?: string,
    teamId?: string,
    tmbId?: string,
    trainingType?: string,
    type?: string,
    updateTime?: Date,
    __v?: number,
    _id?: string,
}

interface ApplicationData {
    appKey?: string,
    checkModel?: string,
    createTime?: Date,
    datasetIds?: string,
    id: string,
    intro?: string,
    maxImport?: string,
    minAbout?: string,
    model?: string,
    name?: string,
    prompt?: string,
    updateTime?: Date,
    userId?: string,
    type?: number,
    appUrl?: string,
    appType?: string,
    isTsoar?: boolean,
}

interface SessionItem {
    appId: string,
    createTime: string,
    id: string | number,
    isDefault: boolean
    owner: string,
    title: string,
    updateTime: string,
}

interface ToolDetail {
    appKey: string,
    appType: string,
    appUrl: string,
    checkModel: string,
    createTime: string,
    datasetIds: string,
    id: string,
    intro: string,
    isTsoar: boolean,
    maxImport: string,
    minAbout: string,
    model: string,
    name: string,
    prompt: string,
    type: number,
    updateTime: string,
    userId: string
}

interface ToolExecInfo {
    appId: string,
    createTime: string,
    id: string,
    input: string,
    output: string,
    prompt: string,
    updateTime: string,
    userId: string,
}

interface McpItem {
  name: string,
  desc: string,
  type: string,
  value: string,
  password: boolean,
}

export type {
    KnowledgeBaseModal,
    DataSetModal,
    DateSetDetailModal,
    ApplicationData,
    SessionItem,
    ToolDetail,
    ToolExecInfo,
    McpItem
}